import "pkl:yaml"

local parser = new yaml.Parser {
  useMapping = true
}

local parsed = parser.parse("""
  foo: bar
  baz:
    -
      biz: biz
      buz: buz
  """)

res1 = parsed

res2 = parsed is Mapping

res3 = parsed["baz"][0] is Mapping

res4 = parser.parse("""
  ? baz: qux
  : 2
  foo: bar
  """)
